package com.tina.service;

import com.tina.entity.Employee;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;
import org.springframework.stereotype.Repository;
import org.springframework.validation.annotation.Validated;

import javax.validation.Valid;
import java.util.List;

/**
 * 员工Service接口
 *
 * @author Tina
 * @since 2020-07-01
 */
@Validated
public interface EmployeeService {
    /**
     * 查询全部员工
     *
     * @return
     */
    public List<Employee> empList();

    /**
     * 新增员工
     *
     * @param emp
     * @return
     */
    public Integer saveEmp(@Valid Employee emp);

    /**
     * 删除员工
     *
     * @param empId
     * @return
     */
    public Integer delEmp(Integer empId);

    /**
     * 编辑员工
     *
     * @param emp
     * @return
     */
    public Integer editEmp(@Valid Employee emp);
}
